<section layout="row" layout-align="center-center" class="pagination-group">
    <md-button class="left" ng-disabled="vm.currentPage == 1" ng-click="vm.setPage(1)">&lt;&lt;</md-button>
    <md-button ng-disabled="!vm.prev" ng-click="vm.setPage(vm.prev.page)">&lt;</md-button>
    
    <md-button 
        ng-repeat="p in [vm.linkGroupFirst(), vm.linkGroupLast()] | makeRange"
        ng-class="{ 'active': p == vm.currentPage }"
        ng-click="vm.setPage(p)">
        {{ p }}
    </md-button>

    <md-button ng-disabled="!vm.next" ng-click="vm.setPage(vm.next.page)">&gt;</md-button>
    <md-button class="right" ng-disabled="!vm.last || vm.currentPage == vm.last.page" ng-click="vm.setPage(vm.last.page)">&gt;&gt;</md-button>
</section>